<template>
   <div>
     <Drawer title="消费明细" v-model="drawer" width="880" :styles="styles">
         <Form inline>
             <FormItem>
                  <DatePicker type="daterange" style="width:320px" v-model="day" format="yyyy年MM月dd日" ></DatePicker>
             </FormItem>
             <FormItem>
    <Select v-model="model2" multiple filterable :max-tag-count ="5">
        <Option v-for="item in projectList" :value="item.value" :key="item.value">{{ item.label}}</Option>
    </Select>
             </FormItem>
         </Form>
        <Table :columns="columns" :data="data" size="small" border></Table>
        <div class="ivu-mt iuv-text-center">
            <Page :total="100" show-elevator show-sizer show-total size="small"></Page>
        </div>
     </Drawer>
        </div>
</template>
<script>
    export default {
        name: 'costRecord',
        data () {
            return {
                drawer: false,
                model2: '',
                value: '',
                day: ['2020-04-06', '2020-04-06'],
                styles: {
                    height: 'calc(100% - 55px)',
                    overflow: 'auto',
                    paddingBottom: '53px',
                    position: 'static'
                },
                projectList: [
                    {
                        value: '308',
                        label: '308'
                    },
                    {
                        value: '311',
                        label: '311'
                    },
                    {
                        value: '药浴',
                        label: '药浴'
                    },
                    {
                        value: '激光点阵',
                        label: '激光点阵'
                    },
                    {
                        value: '百行针',
                        label: '百行针'
                    },
                    {
                        value: '激光疗法',
                        label: '激光疗法'
                    },
                    {
                        value: '药品',
                        label: '药品'
                    }
                ],
                columns: [
                    {
                        title: '业务类型',
                        key: 'type',
                        minWidth: 108
                    },
                    {
                        title: '医生',
                        key: 'doctor',
                        minWidth: 88
                    },
                    {
                        title: '消费项目名称',
                        key: 'name',
                        minWidth: 150
                    },
                    {
                        title: '单位',
                        key: 'unit',
                        width: 70
                    },
                    {
                        title: '数量',
                        key: 'number',
                        width: 70
                    },
                    {
                        title: '单价',
                        key: 'unitPrice',
                        width: 80
                    },
                    {
                        title: '总价',
                        key: 'totalPrice',
                        minWidth: 80
                    },
                    {
                        title: '折后总价',
                        key: 'discount',
                        minWidth: 118
                    },
                    {
                        title: '发生时间',
                        key: 'time',
                        width: 150
                    }
                ],
                data: [
                    {
                        type: '门诊',
                        doctor: '刘斌',
                        name: '驱白巴布期片',
                        unit: '盒',
                        number: '3',
                        unitPrice: '21.00',
                        totalPrice: '63.00',
                        discount: '53.00',
                        time: '2020-03-21 16:31'
                    },
                    {
                        type: '门诊',
                        doctor: '刘斌',
                        name: '驱白巴布期片',
                        unit: '盒',
                        number: '3',
                        unitPrice: '21.00',
                        totalPrice: '63.00',
                        discount: '53.00',
                        time: '2020-03-21 16:31'
                    },
                    {
                        type: '门诊',
                        doctor: '刘斌',
                        name: '驱白巴布期片',
                        unit: '盒',
                        number: '3',
                        unitPrice: '21.00',
                        totalPrice: '63.00',
                        discount: '53.00',
                        time: '2020-03-21 16:31'
                    },
                    {
                        type: '门诊',
                        doctor: '刘斌',
                        name: '驱白巴布期片',
                        unit: '盒',
                        number: '3',
                        unitPrice: '21.00',
                        totalPrice: '63.00',
                        discount: '53.00',
                        time: '2020-03-21 16:31'
                    },
                    {
                        type: '门诊',
                        doctor: '刘斌',
                        name: '驱白巴布期片',
                        unit: '盒',
                        number: '3',
                        unitPrice: '21.00',
                        totalPrice: '63.00',
                        discount: '53.00',
                        time: '2020-03-21 16:31'
                    }
                ]
            };
        },
        methods: {
            handleCostDetail () {
                this.drawer = true;
            }
        }
    }
</script>
<style scoped>

</style>
